#ifndef _SERVICE_H_
#define _SERVICE_H_


/*
	class : Service
	desc : Used to encapsulate a service and
		let it make a little more sense and 
		easier to use. Mainly for service oriented
		architecture patterns on embedded systems.
		For example if you want to read and write to 		
		usart it might be easier to create an soa that
		runs separate read and write services and checks if
		there is a request and performs all requests in order.
		This can make it easier to separate your code into more 
		logically blocks ideally
*/
class Service
{
	public :
		//starts a service to perform actions if it can.
		virtual void start(){};
		//stops a service permanently if needed
		virtual void stop(){}; 
		//continues running a service as needed if needed
		virtual void run(){};

		//VARIABLES//
		//tells if this service is finished running
		bool finished;

};


#endif
